import { get, post, postFrom, postFromFile } from '../utils/request';

// 登录
export function login(e) {
    return postFrom('/dmsp-oauth/oauth/token', e);
};
// 发多单提醒
export function getNoticeStatus() {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/notice-status');
};
// 获取首页数量
export function getHomeCount() {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/count');
};
// 获取用户信息
export function getInfo() {
    return get('/dmsp-oauth/users/info');
};
// 查询发货单列表
export function getShipmentList(e) {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/page/no_delivery', e);
};
// 开始发货
export function startDelivery(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/start-delivery', e);
};
// 货物暂滞
export function transientStatus(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/update/transient-status', e);
};
// 获取我的发货单独订单
export function getShipmentData(e) {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/id', e);
};
// 获取我的未发货
export function getMyShipmentNew() {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/my/delivery_ing');
};
// 获取我的已发货
export function getMyShipmentOld(e) {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/page/my/complete_delivery', e);
};
// 获取我的已发货统计
export function getMyShipmentOldCount() {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/page/my/complete_delivery/count');
};
// 取消发货
export function cancelDelivery(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/cancel-delivery', e);
};
// 破损登记列表查询
export function getDamageList(e) {
    return get('/bmt-separate-stock/separate/app/damage-info/query/page', e);
};

// 新增破损信息
export function damageInfoSave(e) {
    return post('/bmt-separate-stock/separate/app/damage-info/save', e);
};
// 编辑破损信息
export function damageInfoUpdate(e) {
    return post('/bmt-separate-stock/separate/app/damage-info/update', e);
};
// 破损信息图片上传
export function UpdateFile(e) {
    return postFromFile('/dmsp-all/file/oper/upload', e);
};
// 获取破损详情
export function getDamageInfo(e) {
    return get('/bmt-separate-stock/separate/app/damage-info/id', e);
};
// 根据发货单ID和主单号或分单号查询破损记录，主单号或分单号不能同时为空
export function getCargoBill(e) {
    return get('/bmt-separate-stock/separate/app/damage-info/query/cargo-bill', e);
};
// 发货完成
export function shipmentCompleted(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/complete-delivery', e);
};
// 暂存发货
export function holdCompleteDelivery(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/hold-complete-delivery', e);
};
// 出库交接列表查询
export function getdeliveryHandoverList(e) {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/page/complete_delivery', e);
};

// 点击开始交接
export function startHandover(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/start-handover', e);
};
// 交接完成
export function completeHandover(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/complete-handover', e);
};
// 交接暂存
export function holdCompleteHandover(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/hold-complete-handover', e);
};
// 正在交接的货
export function getNothandedOver(e) {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/my/handover_ing', e);
};

// 我的交接已完成的交接
export function getHandoverList(e) {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/my/complete_handover', e);
};
// 出库交接完成统计
export function getHandoverListOldCount(e) {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/query/page/my/complete_handover/count');
};
// 取消交接
export function cancelHandover(e) {
    return post('/bmt-separate-stock/separate/app/deliver-cargo-bill/cancel-handover', e);
};
// 出货口数据获取
export function getExportCargo() {
    return get('/bmt-separate-stock/separate/app/export-cargo/group-code');
};
// 发货单件数增加方式
export function deliverNumAddType() {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/deliver-num-add-type');
};
// 出库单件数增加方式
export function outboundNumAddType() {
    return get('/bmt-separate-stock/separate/app/deliver-cargo-bill/outbound-num-add-type');
};
